﻿@model IEnumerable<ASM_Group2.Models.OrderDetail>

@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table class="table">
    <tr>
       
        <th>
            @Html.DisplayNameFor(model => model.Product.Name)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Product.Image)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Quantity)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Product.Size)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Product.Color)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Totalprice)
        </th>
        <th></th>
    </tr>

    @foreach (var item in Model)
    {
        <tr>
          
            <td>
                @Html.DisplayFor(modelItem => item.Product.Name)
            </td>
            <td>
                <img width="100" height="100" src="~/Images/@Html.DisplayFor(modelItem => item.Product.Image)" />
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Quantity)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Product.Size)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Product.Color)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Totalprice)
            </td>
        
          
        </tr>
    }

</table>
